package com.jiaai.web.zfp_back.member;

import com.alibaba.dubbo.config.annotation.Reference;
import com.jiaai.member.api.IMemberGiftApi;
import com.jiaai.util.RestResultGenerator;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

/**
 * <p>
 * 会员礼物列表 前端控制器
 * </p>
 *
 * @author 佳爱网络科技
 * @since 2018-03-26
 */
@RestController
@RequestMapping("/api/v1/admin/memberGift")
public class TMemberGiftController {
    @Reference
    private IMemberGiftApi iMemberGiftApi;

    @GetMapping("/findMyGift")
    public Object findMyGift(@RequestParam(defaultValue = "0", required = false) Integer curr,@RequestParam String mId) throws Exception{
        return RestResultGenerator.genSuccessResult(iMemberGiftApi.findMyGift(curr, mId));
    }

    @GetMapping("/findGift")
    public Object findGift(@RequestParam(defaultValue = "0", required = false) Integer curr,@RequestParam String mId) throws Exception{
        return RestResultGenerator.genSuccessResult(iMemberGiftApi.findGift(curr, mId));
    }
	
}
